import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'
import '@/tool/element'
//表格
import TreeTable from 'vue-table-with-tree-grid'
Vue.component('tree-table', TreeTable)
//时间格式插件
import moment from 'moment'
Vue.config.productionTip = false
//函数
import lodash from 'lodash'
Vue.prototype.lodash = lodash
//分辨级别
Vue.filter('eve', function (v) {
  return v == 0 ? '一级' : v == 1 ? '二级' : '三级'
})
//分辨标签颜色
Vue.filter('lev', function (v) {
  return v == 0 ? '' : v == 1 ? 'success' : 'danger'
})
//处理时间格式
Vue.filter('trmes', function (v) {
  return moment(v * 1000).format('YYYY/MM/DD hh:mm:ss');
})
new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
